package erz.printing.police.notch;

import android.os.Build;

public class RomUtils {

    public static boolean isHuaweiRom() {
        String mf = Build.MANUFACTURER;
        return (mf != null) && mf.contains("HUAWEI");
    }

    public static boolean isMiuiRom() {
        String prop = getSystemProperty("ro.miui.ui.version.name");
        return (prop != null) && (prop.length() > 0);
    }

    public static boolean isOppoRom() {
        String br = getSystemProperty("ro.product.brand");
        return (br != null) && br.toLowerCase().contains("oppo");
    }

    public static boolean isVivoRom() {
        String name = getSystemProperty("ro.vivo.os.name");
        return (name != null) && name.toLowerCase().contains("funtouch");
    }

    private static String getSystemProperty(String propName) {
        return SystemProperties.get(propName);
    }
}
